<{include file='customer/head.html'}>
<body>
	<div class="akrPop">
		<form id="frm" action="" target="f" method="post" enctype="multipart/form-data">
			<ul class="ulForm">
				<li>
					<label class="form-label">名称：</label>
					<div class="form-input">
						<input name="name" value="" class="inputText">
					</div>
				</li>
				<li>
					<label class="form-label">客户：</label>
					<div class="form-input">
					<select name="custmoerid">
						<{foreach from=$customerlist item=vo}>
							<option value="<{$vo.id}>"><{$vo.name}></option>
						<{/foreach}>
					</select></div>
				</li>
				
				<li>
					<label class="form-label">技术：</label>
					<div class="form-input">
						<select name="technologyuid">
							<{foreach from=$technologyuserlist item=vo}>
								<option value="<{$vo.id}>"><{$vo.displayname}></option>
							<{/foreach}>
						</select>
					</div>
				</li>
				<li>
					<label class="form-label">状态：</label>
					<div class="form-input">
						<select name="status">
							<option value="0">开发中</option>
							<option value="1">已上线</option>
						</select>
					</div>
				</li>
				<li>
					<label class="form-label">描述：</label>
					<div class="form-input">
						<textarea name="description" value=""></textarea>
					</div>
				</li>
				<li>
					<div class="form-input">
						<input type="button" onclick="add()" status="0" value="提交" class="akrBtn akrBtn-md blue">
					</div>
				</li>
			</ul>
		</form>
	</div>
	<script type="text/javascript">
		var addstatus=true;
		function add(){
			var data = $("form").serialize();
			var href='../ProjectIndex/add';
			if(addstatus){
                addstatus = false;
                _ajaxs.post(href,data,function _return(hdata)<{literal}>{
                    if(hdata.status){
                        _layer_admin.successMsg(hdata.message,function(){
                            var index = parent.layer.getFrameIndex(window.name); //获取窗口索引
                            parent.layer.close(index);
                            parent.location.reload();
                        });
                    }else{
                        addstatus = true;
                        _layer_admin.successMsg(hdata.message);
                    }
                }<{/literal}>)
            }
		}
	</script>
</body>
</html>